# CONFIG -= qt
QT       +=  network
TEMPLATE = lib
DEFINES += CTRLBOX_LIBRARY

CONFIG += c++17

# You can make your code fail to compile if it uses deprecated APIs.
# In order to do so, uncomment the following line.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000    # disables all the APIs deprecated before Qt 6.0.0
TARGETNAME = CtrlBox
win32 {

    CONFIG(debug, debug|release) { ##debug
    DESTDIR = $${PWD}/bin/debug
    TARGET = $${TARGETNAME}d
    }else{
    DESTDIR = $${PWD}/bin/release
    TARGET = $${TARGETNAME}
    }

COPY_PATH = $$replace(PWD, /, \\)
    system("copy $$COPY_PATH\\Protocol.h        $$COPY_PATH\\bin\\include\\Protocol.h ")
    system("copy $$COPY_PATH\\CtrlBoxGlobal.h        $$COPY_PATH\\bin\\include\\CtrlBoxGlobal.h ")
}

SOURCES += \
    # CtrlBox.cpp \
    Protocol.cpp \
    UDPSocket.cpp

HEADERS += \
    # CtrlBox.h \
    CtrlBoxGlobal.h \
    Protocol.h \
    UDPSocket.h

# Default rules for deployment.
unix {
    target.path = /usr/lib
}
!isEmpty(target.path): INSTALLS += target
